﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Text;

namespace IceDog.DNL.CSharp.DesignPattern.SingletonPattern.Year
{
    /// <summary>
    /// 登记式/静态内部类
    /// </summary>
    public class YearManager
    {
        private static class Holder
        {
            internal static readonly YearManager InnerManager = new YearManager();
        }

        private YearManager()
        {
            InitCounter += 1;
        }
        public static int InitCounter;
        public static YearManager Instance => Holder.InnerManager;

        public string Get2018Ch()
        {
            return "二零一八";
        }

        public string Get2018Number()
        {
            return "2018";
        }
    }
}
